<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <style type="text/css">
        li:hover{
            cursor: pointer;
        }
    </style>
</head>
<body>
    <ul>
        <li>0</li>
        <li>1</li>
        <li>2</li>
        <li>3</li>
    </ul>
    <script>
       /* function say667() {
            var num=666;
            var sayAlert=function () {
                alert(num);
            }
            num++;
            return sayAlert;
        }
    var sayalert= say667();
        sayalert();*/

      /*  var nodes=document.getElementsByTagName("li");
        for(var i=0;i<nodes.length;i++)
        {
             nodes[i].onclick=(function (i) {
               return function () {
                   console.log(i);
               }
             })(i);

            }
*/
        var colors=["red","blue","green","pink","white"];
        var remove=colors.splice(0,1,"newcolor3","newcolor4");
        console.log(colors);
        var arr1=["a","b","c","d","e"];
        var arr2=arr1.splice(1,2,"F");
        console.log(arr1);

    </script>
</body>
</html>